package com.dongqi.deviceData.entity;

import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.annotation.JsonFormat;

import java.io.Serializable;
import java.util.Date;

/**
 * 设备数据-车辆
 *
 * @TableName device_vehicle
 */
@TableName("device_vehicle")
public class DeviceVehicleEntity implements Serializable {

    /**
     * id
     */
    private Long id;

    /**
     * 设备编号
     */
    private String deviceNo;

    /**
     * 车辆编号
     */
    private String carNo;

    /**
     * 车辆型号
     */
    private String carModel;

    /**
     * 设备状态
     */
    private String status;

    /**
     * 当前车速
     */
    private String currentSpeed;

    /**
     * 车重
     */
    private String carWeight;

    /**
     * 储能剩余
     */
    private String energyResidue;

    /**
     * 实时功耗
     */
    private String realPowerLoss;

    /**
     * 续航时间
     */
    private String enduranceTime;

    /**
     * 可续航距离
     */
    private String enduranceDistance;

    /**
     * 车辆倾角
     */
    private String inclinationAngle;

    /**
     * 发动机状态
     */
    private String energyStatus;

    /**
     * 创建时间
     */
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    private Date createTime;

    /**
     * 更新时间
     */
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    private Date updateTime;

    /**
     * 备用1
     */
    private String bak1;

    /**
     * 备用2
     */
    private String bak2;

    /**
     * 备用3
     */
    private String bak3;

    /**
     * 经度
     */
    private String longitude;

    /**
     * 纬度
     */
    private String latitude;

    /**
     * 时间戳
     */
    private String timestp;

    public String getTimestp() {
        return timestp;
    }

    public void setTimestp(String timestp) {
        this.timestp = timestp;
    }

    public String getLongitude() {
        return longitude;
    }

    public void setLongitude(String longitude) {
        this.longitude = longitude;
    }

    public String getLatitude() {
        return latitude;
    }

    public void setLatitude(String latitude) {
        this.latitude = latitude;
    }

    public static long getSerialVersionUID() {
        return serialVersionUID;
    }

    private static final long serialVersionUID = 1L;


    public Long getId() {
        return id;
    }


    public void setId(Long id) {
        this.id = id;
    }


    public String getDeviceNo() {
        return deviceNo;
    }


    public void setDeviceNo(String deviceNo) {
        this.deviceNo = deviceNo;
    }


    public String getCarNo() {
        return carNo;
    }


    public void setCarNo(String carNo) {
        this.carNo = carNo;
    }


    public String getCarModel() {
        return carModel;
    }


    public void setCarModel(String carModel) {
        this.carModel = carModel;
    }


    public String getStatus() {
        return status;
    }


    public void setStatus(String status) {
        this.status = status;
    }


    public String getCurrentSpeed() {
        return currentSpeed;
    }


    public void setCurrentSpeed(String currentSpeed) {
        this.currentSpeed = currentSpeed;
    }


    public String getCarWeight() {
        return carWeight;
    }


    public void setCarWeight(String carWeight) {
        this.carWeight = carWeight;
    }


    public String getEnergyResidue() {
        return energyResidue;
    }


    public void setEnergyResidue(String energyResidue) {
        this.energyResidue = energyResidue;
    }


    public String getRealPowerLoss() {
        return realPowerLoss;
    }


    public void setRealPowerLoss(String realPowerLoss) {
        this.realPowerLoss = realPowerLoss;
    }


    public String getEnduranceTime() {
        return enduranceTime;
    }


    public void setEnduranceTime(String enduranceTime) {
        this.enduranceTime = enduranceTime;
    }


    public String getEnduranceDistance() {
        return enduranceDistance;
    }


    public void setEnduranceDistance(String enduranceDistance) {
        this.enduranceDistance = enduranceDistance;
    }


    public String getInclinationAngle() {
        return inclinationAngle;
    }


    public void setInclinationAngle(String inclinationAngle) {
        this.inclinationAngle = inclinationAngle;
    }


    public String getEnergyStatus() {
        return energyStatus;
    }


    public void setEnergyStatus(String energyStatus) {
        this.energyStatus = energyStatus;
    }


    public Date getCreateTime() {
        return createTime;
    }


    public void setCreateTime(Date createTime) {
        this.createTime = createTime;
    }


    public Date getUpdateTime() {
        return updateTime;
    }


    public void setUpdateTime(Date updateTime) {
        this.updateTime = updateTime;
    }


    public String getBak1() {
        return bak1;
    }


    public void setBak1(String bak1) {
        this.bak1 = bak1;
    }


    public String getBak2() {
        return bak2;
    }


    public void setBak2(String bak2) {
        this.bak2 = bak2;
    }


    public String getBak3() {
        return bak3;
    }


    public void setBak3(String bak3) {
        this.bak3 = bak3;
    }

    @Override
    public boolean equals(Object that) {
        if (this == that) {
            return true;
        }
        if (that == null) {
            return false;
        }
        if (getClass() != that.getClass()) {
            return false;
        }
        DeviceVehicleEntity other = (DeviceVehicleEntity) that;
        return (this.getId() == null ? other.getId() == null : this.getId().equals(other.getId()))
                && (this.getDeviceNo() == null ? other.getDeviceNo() == null : this.getDeviceNo().equals(other.getDeviceNo()))
                && (this.getCarNo() == null ? other.getCarNo() == null : this.getCarNo().equals(other.getCarNo()))
                && (this.getCarModel() == null ? other.getCarModel() == null : this.getCarModel().equals(other.getCarModel()))
                && (this.getStatus() == null ? other.getStatus() == null : this.getStatus().equals(other.getStatus()))
                && (this.getCurrentSpeed() == null ? other.getCurrentSpeed() == null : this.getCurrentSpeed().equals(other.getCurrentSpeed()))
                && (this.getCarWeight() == null ? other.getCarWeight() == null : this.getCarWeight().equals(other.getCarWeight()))
                && (this.getEnergyResidue() == null ? other.getEnergyResidue() == null : this.getEnergyResidue().equals(other.getEnergyResidue()))
                && (this.getRealPowerLoss() == null ? other.getRealPowerLoss() == null : this.getRealPowerLoss().equals(other.getRealPowerLoss()))
                && (this.getEnduranceTime() == null ? other.getEnduranceTime() == null : this.getEnduranceTime().equals(other.getEnduranceTime()))
                && (this.getEnduranceDistance() == null ? other.getEnduranceDistance() == null : this.getEnduranceDistance().equals(other.getEnduranceDistance()))
                && (this.getInclinationAngle() == null ? other.getInclinationAngle() == null : this.getInclinationAngle().equals(other.getInclinationAngle()))
                && (this.getEnergyStatus() == null ? other.getEnergyStatus() == null : this.getEnergyStatus().equals(other.getEnergyStatus()))
                && (this.getCreateTime() == null ? other.getCreateTime() == null : this.getCreateTime().equals(other.getCreateTime()))
                && (this.getUpdateTime() == null ? other.getUpdateTime() == null : this.getUpdateTime().equals(other.getUpdateTime()))
                && (this.getBak1() == null ? other.getBak1() == null : this.getBak1().equals(other.getBak1()))
                && (this.getBak2() == null ? other.getBak2() == null : this.getBak2().equals(other.getBak2()))
                && (this.getBak3() == null ? other.getBak3() == null : this.getBak3().equals(other.getBak3()))
                && (this.getLongitude() == null ? other.getLongitude() == null : this.getLongitude().equals(other.getLongitude()))
                && (this.getLatitude() == null ? other.getLatitude() == null : this.getLatitude().equals(other.getLatitude()))
                && (this.getTimestp() == null ? other.getTimestp() == null : this.getTimestp().equals(other.getTimestp()));
    }

    @Override
    public int hashCode() {
        final int prime = 31;
        int result = 1;
        result = prime * result + ((getId() == null) ? 0 : getId().hashCode());
        result = prime * result + ((getDeviceNo() == null) ? 0 : getDeviceNo().hashCode());
        result = prime * result + ((getCarNo() == null) ? 0 : getCarNo().hashCode());
        result = prime * result + ((getCarModel() == null) ? 0 : getCarModel().hashCode());
        result = prime * result + ((getStatus() == null) ? 0 : getStatus().hashCode());
        result = prime * result + ((getCurrentSpeed() == null) ? 0 : getCurrentSpeed().hashCode());
        result = prime * result + ((getCarWeight() == null) ? 0 : getCarWeight().hashCode());
        result = prime * result + ((getEnergyResidue() == null) ? 0 : getEnergyResidue().hashCode());
        result = prime * result + ((getRealPowerLoss() == null) ? 0 : getRealPowerLoss().hashCode());
        result = prime * result + ((getEnduranceTime() == null) ? 0 : getEnduranceTime().hashCode());
        result = prime * result + ((getEnduranceDistance() == null) ? 0 : getEnduranceDistance().hashCode());
        result = prime * result + ((getInclinationAngle() == null) ? 0 : getInclinationAngle().hashCode());
        result = prime * result + ((getEnergyStatus() == null) ? 0 : getEnergyStatus().hashCode());
        result = prime * result + ((getCreateTime() == null) ? 0 : getCreateTime().hashCode());
        result = prime * result + ((getUpdateTime() == null) ? 0 : getUpdateTime().hashCode());
        result = prime * result + ((getBak1() == null) ? 0 : getBak1().hashCode());
        result = prime * result + ((getBak2() == null) ? 0 : getBak2().hashCode());
        result = prime * result + ((getBak3() == null) ? 0 : getBak3().hashCode());
        result = prime * result + ((getLongitude() == null) ? 0 : getLongitude().hashCode());
        result = prime * result + ((getLatitude() == null) ? 0 : getLatitude().hashCode());
        result = prime * result + ((getTimestp() == null) ? 0 : getTimestp().hashCode());
        return result;
    }

    @Override
    public String toString() {
        StringBuilder sb = new StringBuilder();
        sb.append(getClass().getSimpleName());
        sb.append(" [");
        sb.append("Hash = ").append(hashCode());
        sb.append(", id=").append(id);
        sb.append(", deviceNo=").append(deviceNo);
        sb.append(", carNo=").append(carNo);
        sb.append(", carModel=").append(carModel);
        sb.append(", status=").append(status);
        sb.append(", currentSpeed=").append(currentSpeed);
        sb.append(", carWeight=").append(carWeight);
        sb.append(", energyResidue=").append(energyResidue);
        sb.append(", realPowerLoss=").append(realPowerLoss);
        sb.append(", enduranceTime=").append(enduranceTime);
        sb.append(", enduranceDistance=").append(enduranceDistance);
        sb.append(", inclinationAngle=").append(inclinationAngle);
        sb.append(", energyStatus=").append(energyStatus);
        sb.append(", createTime=").append(createTime);
        sb.append(", updateTime=").append(updateTime);
        sb.append(", bak1=").append(bak1);
        sb.append(", bak2=").append(bak2);
        sb.append(", bak3=").append(bak3);
        sb.append(", longitude=").append(longitude);
        sb.append(", latitude=").append(latitude);
        sb.append(", timestp=").append(timestp);
        sb.append(", serialVersionUID=").append(serialVersionUID);
        sb.append("]");
        return sb.toString();
    }
}